﻿using System;
using System.ServiceModel;
using Silverlight.Training.Client.Common.ServiceReference.Contracts;
using Silverlight.Training.Client.Common.ServiceReference.Feedbacks;

namespace Silverlight.Training.Client.Common.ServiceReference.Interfaces
{
    [ServiceContract(Namespace = ServiceConstants.ServiceNamespace, Name = "EMService", 
                        ConfigurationName = "Silverlight.Training.Client.Common.ServiceReference.Interfaces.IEMService")]
    public interface IEMService
    {
        #region Employee

        [OperationContractAttribute(AsyncPattern = true, 
                                    Action = "http://silverlight.training/EMService/GetEmployeeCollection", 
                                    ReplyAction = "http://silverlight.training/EMService/GetEmployeeCollectionResponse")]
        IAsyncResult BeginGetEmployeeCollection(AsyncCallback callback, object asyncState);

        CollectionFeedback<Employee> EndGetEmployeeCollection(IAsyncResult result);
        //----------------
        [OperationContractAttribute(AsyncPattern = true,
                                    Action = "http://silverlight.training/EMService/GetSingleEmployee",
                                    ReplyAction = "http://silverlight.training/EMService/GetSingleEmployeeResponse")]
        IAsyncResult BeginGetSingleEmployee(int employeeID, AsyncCallback callback, object asyncState);

        SingleFeedback<Employee> EndGetSingleEmployee(IAsyncResult result);
        ////----------------
        //[OperationContractAttribute(AsyncPattern = true,
        //                            Action = "http://silverlight.training/EMService/InsertEmployee",
        //                            ReplyAction = "http://silverlight.training/EMService/InsertEmployeeResponse")]
        //IAsyncResult BeginInsertEmployee(Employee data, AsyncCallback callback, object asyncState);

        //SingleFeedback<int> EndInsertEmployee(IAsyncResult result);
        ////----------------
        //[OperationContractAttribute(AsyncPattern = true,
        //                            Action = "http://silverlight.training/EMService/UpdateEmployee",
        //                            ReplyAction = "http://silverlight.training/EMService/UpdateEmployeeResponse")]
        //IAsyncResult BeginUpdateEmployee(Employee data, AsyncCallback callback, object asyncState);

        //Feedback EndUpdateEmployee(IAsyncResult result);
        ////----------------
        //[OperationContractAttribute(AsyncPattern = true,
        //                            Action = "http://silverlight.training/EMService/DeleteEmployee",
        //                            ReplyAction = "http://silverlight.training/EMService/DeleteEmployeeResponse")]
        //IAsyncResult BeginDeleteEmployee(Employee data, AsyncCallback callback, object asyncState);

        //Feedback EndDeleteEmployee(IAsyncResult result);
                        
        #endregion

        #region Department

        [OperationContractAttribute(AsyncPattern = true, 
                                    Action = "http://silverlight.training/EMService/GetDepartmentCollection", 
                                    ReplyAction = "http://silverlight.training/EMService/GetDepartmentCollectionResponse")]
        IAsyncResult BeginGetDepartmentCollection(AsyncCallback callback, object asyncState);

        CollectionFeedback<Department> EndGetDepartmentCollection(IAsyncResult result);
        //----------------
        [OperationContractAttribute(AsyncPattern = true, 
                                    Action = "http://silverlight.training/EMService/GetSingleDepartment", 
                                    ReplyAction = "http://silverlight.training/EMService/GetSingleDepartmentResponse")]
        IAsyncResult BeginGetSingleDepartment(int deptID, AsyncCallback callback, object asyncState);

        SingleFeedback<Department> EndGetSingleDepartment(IAsyncResult result);
        ////----------------
        //[OperationContractAttribute(AsyncPattern = true,
        //                            Action = "http://silverlight.training/EMService/InsertDepartment",
        //                            ReplyAction = "http://silverlight.training/EMService/InsertDepartmentResponse")]
        //IAsyncResult BeginInsertDepartment(Department data, AsyncCallback callback, object asyncState);

        //SingleFeedback<int> EndInsertDepartment(IAsyncResult result);
        ////----------------
        //[OperationContractAttribute(AsyncPattern = true,
        //                            Action = "http://silverlight.training/EMService/UpdateDepartment",
        //                            ReplyAction = "http://silverlight.training/EMService/UpdateDepartmentResponse")]
        //IAsyncResult BeginUpdateDepartment(Department data, AsyncCallback callback, object asyncState);

        //Feedback EndUpdateDepartment(IAsyncResult result);
        ////----------------
        //[OperationContractAttribute(AsyncPattern = true,
        //                            Action = "http://silverlight.training/EMService/DeleteDepartment",
        //                            ReplyAction = "http://silverlight.training/EMService/DeleteDepartmentResponse")]
        //IAsyncResult BeginDeleteDepartment(Department data, AsyncCallback callback, object asyncState);

        //Feedback EndDeleteDepartment(IAsyncResult result);
             
        #endregion

        #region JobTitle

        [OperationContractAttribute(AsyncPattern = true, 
                                    Action = "http://silverlight.training/EMService/GetJobTitleCollection", 
                                    ReplyAction = "http://silverlight.training/EMService/GetJobTitleCollectionResponse")]
        IAsyncResult BeginGetJobTitleCollection(AsyncCallback callback, object asyncState);

        CollectionFeedback<JobTitle> EndGetJobTitleCollection(IAsyncResult result);
        //----------------
        [OperationContractAttribute(AsyncPattern = true, 
                                    Action = "http://silverlight.training/EMService/GetSingleJobTitle", 
                                    ReplyAction = "http://silverlight.training/EMService/GetSingleJobTitleResponse")]
        IAsyncResult BeginGetSingleJobTitle(int jTitleID, AsyncCallback callback, object asyncState);

        SingleFeedback<JobTitle> EndGetSingleJobTitle(IAsyncResult result);
        ////----------------
        //[OperationContractAttribute(AsyncPattern = true,
        //                            Action = "http://silverlight.training/EMService/InsertJobTitle",
        //                            ReplyAction = "http://silverlight.training/EMService/InsertJobTitleResponse")]
        //IAsyncResult BeginInsertJobTitle(JobTitle data, AsyncCallback callback, object asyncState);

        //SingleFeedback<int> EndInsertJobTitle(IAsyncResult result);
        ////----------------
        //[OperationContractAttribute(AsyncPattern = true,
        //                            Action = "http://silverlight.training/EMService/UpdateJobTitle",
        //                            ReplyAction = "http://silverlight.training/EMService/UpdateJobTitleResponse")]
        //IAsyncResult BeginUpdateJobTitle(JobTitle data, AsyncCallback callback, object asyncState);

        //Feedback EndUpdateJobTitle(IAsyncResult result);
        ////----------------
        //[OperationContractAttribute(AsyncPattern = true,
        //                            Action = "http://silverlight.training/EMService/DeleteJobTitle",
        //                            ReplyAction = "http://silverlight.training/EMService/DeleteJobTitleResponse")]
        //IAsyncResult BeginDeleteJobTitle(JobTitle data, AsyncCallback callback, object asyncState);

        //Feedback EndDeleteJobTitle(IAsyncResult result);
             
        #endregion

        #region EmployeeType

        [OperationContractAttribute(AsyncPattern = true, 
                                    Action = "http://silverlight.training/EMService/GetEmployeeTypeCollection", 
                                    ReplyAction = "http://silverlight.training/EMService/GetEmployeeTypeCollectionResponse")]
        IAsyncResult BeginGetEmployeeTypeCollection(AsyncCallback callback, object asyncState);

        CollectionFeedback<EmployeeType> EndGetEmployeeTypeCollection(IAsyncResult result);
        //----------------
        [OperationContractAttribute(AsyncPattern = true, 
                                    Action = "http://silverlight.training/EMService/GetSingleEmployeeType", 
                                    ReplyAction = "http://silverlight.training/EMService/GetSingleEmployeeTypeResponse")]
        IAsyncResult BeginGetSingleEmployeeType(int eTypeID, AsyncCallback callback, object asyncState);

        SingleFeedback<EmployeeType> EndGetSingleEmployeeType(IAsyncResult result);
        ////----------------
        //[OperationContractAttribute(AsyncPattern = true,
        //                            Action = "http://silverlight.training/EMService/InsertEmployeeType",
        //                            ReplyAction = "http://silverlight.training/EMService/InsertEmployeeTypeResponse")]
        //IAsyncResult BeginInsertEmployeeType(EmployeeType data, AsyncCallback callback, object asyncState);

        //SingleFeedback<int> EndInsertEmployeeType(IAsyncResult result);
        ////----------------
        //[OperationContractAttribute(AsyncPattern = true,
        //                            Action = "http://silverlight.training/EMService/UpdateEmployeeType",
        //                            ReplyAction = "http://silverlight.training/EMService/UpdateEmployeeTypeResponse")]
        //IAsyncResult BeginUpdateEmployeeType(EmployeeType data, AsyncCallback callback, object asyncState);

        //Feedback EndUpdateEmployeeType(IAsyncResult result);
        ////----------------
        //[OperationContractAttribute(AsyncPattern = true,
        //                            Action = "http://silverlight.training/EMService/DeleteEmployeeType",
        //                            ReplyAction = "http://silverlight.training/EMService/DeleteEmployeeTypeResponse")]
        //IAsyncResult BeginDeleteEmployeeType(EmployeeType data, AsyncCallback callback, object asyncState);

        //Feedback EndDeleteEmployeeType(IAsyncResult result);
             
        #endregion
    }
}
